

<!DOCTYPE html>
<html lang="zh-CN" data-default-color-scheme=auto>



<head>
  <meta charset="UTF-8">
  <link rel="apple-touch-icon" sizes="76x76" href="/img/fluid.png">
  <link rel="icon" href="/img/fluid.png">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0, shrink-to-fit=no">
  <meta http-equiv="x-ua-compatible" content="ie=edge">
  
  <meta name="theme-color" content="#2f4154">
  <meta name="author" content="深海火锅店">
  <meta name="keywords" content="">
  
    <meta name="description" content="项目中遇到的问题对话框 之前在网上copy的，现在我自己也找不到人家原创的了，仅此记录   index.js  123456789101112&#x2F;&#x2F; 多行查看box框export function messageBoxMutiple(content, title, func) &amp;#123;    MessageBox.confirm(content, title, &amp;#123;        typ">
<meta property="og:type" content="article">
<meta property="og:title" content="vue需求">
<meta property="og:url" content="http://example.com/2023/03/26/%E7%BC%96%E7%A8%8B%E8%AF%AD%E8%A8%80/Vue/Vue2/%E9%A1%B9%E7%9B%AE%E4%B8%AD%E9%81%87%E5%88%B0%E7%9A%84%E9%97%AE%E9%A2%98/index.html">
<meta property="og:site_name" content="Hexo">
<meta property="og:description" content="项目中遇到的问题对话框 之前在网上copy的，现在我自己也找不到人家原创的了，仅此记录   index.js  123456789101112&#x2F;&#x2F; 多行查看box框export function messageBoxMutiple(content, title, func) &amp;#123;    MessageBox.confirm(content, title, &amp;#123;        typ">
<meta property="og:locale" content="zh_CN">
<meta property="article:published_time" content="2023-03-25T16:00:00.000Z">
<meta property="article:modified_time" content="2023-03-29T14:57:57.850Z">
<meta property="article:author" content="深海火锅店">
<meta property="article:tag" content="vue需求">
<meta name="twitter:card" content="summary_large_image">
  
  
    <meta name="referrer" content="no-referrer-when-downgrade">
  
  
  <title>vue需求 - Hexo</title>

  <link  rel="stylesheet" href="https://lib.baomitu.com/twitter-bootstrap/4.6.1/css/bootstrap.min.css" />



  <link  rel="stylesheet" href="https://lib.baomitu.com/github-markdown-css/4.0.0/github-markdown.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/hint.css/2.7.0/hint.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.css" />



<!-- 主题依赖的图标库，不要自行修改 -->
<!-- Do not modify the link that theme dependent icons -->

<link rel="stylesheet" href="//at.alicdn.com/t/font_1749284_hj8rtnfg7um.css">



<link rel="stylesheet" href="//at.alicdn.com/t/font_1736178_lbnruvf0jn.css">


<link  rel="stylesheet" href="/css/main.css" />


  <link id="highlight-css" rel="stylesheet" href="/css/highlight.css" />
  
    <link id="highlight-css-dark" rel="stylesheet" href="/css/highlight-dark.css" />
  




  <script id="fluid-configs">
    var Fluid = window.Fluid || {};
    Fluid.ctx = Object.assign({}, Fluid.ctx)
    var CONFIG = {"hostname":"example.com","root":"/","version":"1.9.3","typing":{"enable":true,"typeSpeed":70,"cursorChar":"_","loop":false,"scope":[]},"anchorjs":{"enable":true,"element":"h1,h2,h3,h4,h5,h6","placement":"left","visible":"hover","icon":""},"progressbar":{"enable":true,"height_px":3,"color":"#29d","options":{"showSpinner":false,"trickleSpeed":100}},"code_language":{"enable":true,"default":"TEXT"},"copy_btn":true,"image_caption":{"enable":true},"image_zoom":{"enable":true,"img_url_replace":["",""]},"toc":{"enable":true,"placement":"right","headingSelector":"h1,h2,h3,h4,h5,h6","collapseDepth":0},"lazyload":{"enable":true,"loading_img":"/img/loading.gif","onlypost":false,"offset_factor":2},"web_analytics":{"enable":false,"follow_dnt":true,"baidu":null,"google":null,"gtag":null,"tencent":{"sid":null,"cid":null},"woyaola":null,"cnzz":null,"leancloud":{"app_id":null,"app_key":null,"server_url":null,"path":"window.location.pathname","ignore_local":false}},"search_path":"/local-search.xml"};

    if (CONFIG.web_analytics.follow_dnt) {
      var dntVal = navigator.doNotTrack || window.doNotTrack || navigator.msDoNotTrack;
      Fluid.ctx.dnt = dntVal && (dntVal.startsWith('1') || dntVal.startsWith('yes') || dntVal.startsWith('on'));
    }
  </script>
  <script  src="/js/utils.js" ></script>
  <script  src="/js/color-schema.js" ></script>
  


  
<meta name="generator" content="Hexo 6.3.0"></head>


<body>
  

  <header>
    

<div class="header-inner" style="height: 70vh;">
  <nav id="navbar" class="navbar fixed-top  navbar-expand-lg navbar-dark scrolling-navbar">
  <div class="container">
    <a class="navbar-brand" href="/">
      <strong>Fluid</strong>
    </a>

    <button id="navbar-toggler-btn" class="navbar-toggler" type="button" data-toggle="collapse"
            data-target="#navbarSupportedContent"
            aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
      <div class="animated-icon"><span></span><span></span><span></span></div>
    </button>

    <!-- Collapsible content -->
    <div class="collapse navbar-collapse" id="navbarSupportedContent">
      <ul class="navbar-nav ml-auto text-center">
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/">
                <i class="iconfont icon-home-fill"></i>
                首页
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/archives/">
                <i class="iconfont icon-archive-fill"></i>
                归档
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/categories/">
                <i class="iconfont icon-category-fill"></i>
                分类
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/tags/">
                <i class="iconfont icon-tags-fill"></i>
                标签
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/about/">
                <i class="iconfont icon-user-fill"></i>
                关于
              </a>
            </li>
          
        
        
          <li class="nav-item" id="search-btn">
            <a class="nav-link" target="_self" href="javascript:;" data-toggle="modal" data-target="#modalSearch" aria-label="Search">
              &nbsp;<i class="iconfont icon-search"></i>&nbsp;
            </a>
          </li>
          
        
        
          <li class="nav-item" id="color-toggle-btn">
            <a class="nav-link" target="_self" href="javascript:;" aria-label="Color Toggle">&nbsp;<i
                class="iconfont icon-dark" id="color-toggle-icon"></i>&nbsp;</a>
          </li>
        
      </ul>
    </div>
  </div>
</nav>

  

<div id="banner" class="banner" parallax=true
     style="background: url('/img/background.jpg') no-repeat center center; background-size: cover;">
  <div class="full-bg-img">
    <div class="mask flex-center" style="background-color: rgba(0, 0, 0, 0.3)">
      <div class="banner-text text-center fade-in-up">
        <div class="h2">
          
            <span id="subtitle" data-typed-text="vue需求"></span>
          
        </div>

        
          
  <div class="mt-3">
    
    
      <span class="post-meta">
        <i class="iconfont icon-date-fill" aria-hidden="true"></i>
        <time datetime="2023-03-26 00:00" pubdate>
          2023年3月26日 凌晨
        </time>
      </span>
    
  </div>

  <div class="mt-1">
    
      <span class="post-meta mr-2">
        <i class="iconfont icon-chart"></i>
        
          13k 字
        
      </span>
    

    
      <span class="post-meta mr-2">
        <i class="iconfont icon-clock-fill"></i>
        
        
        
          105 分钟
        
      </span>
    

    
    
  </div>


        
      </div>

      
    </div>
  </div>
</div>

</div>

  </header>

  <main>
    
      

<div class="container-fluid nopadding-x">
  <div class="row nomargin-x">
    <div class="side-col d-none d-lg-block col-lg-2">
      

    </div>

    <div class="col-lg-8 nopadding-x-md">
      <div class="container nopadding-x-md" id="board-ctn">
        <div id="board">
          <article class="post-content mx-auto">
            <!-- SEO header -->
            <h1 style="display: none">vue需求</h1>
            
            
              <div class="markdown-body">
                
                <h1 id="项目中遇到的问题"><a href="#项目中遇到的问题" class="headerlink" title="项目中遇到的问题"></a>项目中遇到的问题</h1><h2 id="对话框"><a href="#对话框" class="headerlink" title="对话框"></a>对话框</h2><blockquote>
<p>之前在网上copy的，现在我自己也找不到人家原创的了，仅此记录</p>
</blockquote>
<blockquote>
<p>index.js</p>
</blockquote>
<figure class="highlight js"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br></pre></td><td class="code"><pre><code class="hljs js"><span class="hljs-comment">// 多行查看box框</span><br><span class="hljs-keyword">export</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">messageBoxMutiple</span>(<span class="hljs-params">content, title, func</span>) &#123;<br>    <span class="hljs-title class_">MessageBox</span>.<span class="hljs-title function_">confirm</span>(content, title, &#123;<br>        <span class="hljs-attr">type</span>: <span class="hljs-string">&quot;success&quot;</span>,<br>        <span class="hljs-attr">showConfirmButton</span>: <span class="hljs-literal">false</span>,<br>        <span class="hljs-attr">showCancelButton</span>: <span class="hljs-literal">false</span>,<br>        <span class="hljs-attr">dangerouslyUseHTMLString</span>: <span class="hljs-literal">true</span><br>    &#125;).<span class="hljs-title function_">then</span>(<span class="hljs-keyword">function</span> (<span class="hljs-params"></span>) &#123;<br>        <span class="hljs-title function_">func</span>();<br>    &#125;).<span class="hljs-title function_">catch</span>(<span class="hljs-function">() =&gt;</span> &#123;<br>    &#125;);<br>&#125;<br></code></pre></td></tr></table></figure>

<blockquote>
<p>在需要引入的vue组件内引入使用</p>
</blockquote>
<figure class="highlight js"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br></pre></td><td class="code"><pre><code class="hljs js"><span class="hljs-comment">// 引入</span><br><span class="hljs-keyword">import</span> &#123;messageBoxMutiple&#125; <span class="hljs-keyword">from</span> <span class="hljs-string">&quot;@/utils&quot;</span>;<br><br><br><span class="hljs-comment">// 使用</span><br><span class="hljs-keyword">var</span> str = <span class="hljs-string">&quot;&quot;</span>;<br><span class="hljs-keyword">var</span> msg = [<br><span class="hljs-string">`姓名:<span class="hljs-subst">$&#123;<span class="hljs-variable language_">this</span>.user.name&#125;</span>`</span>,<br><span class="hljs-string">`性别:<span class="hljs-subst">$&#123;<span class="hljs-variable language_">this</span>.user.gender&#125;</span>`</span>,<br>];<br>msg.<span class="hljs-title function_">forEach</span>(<span class="hljs-function">(<span class="hljs-params">item</span>) =&gt;</span> &#123;<br>str += <span class="hljs-string">`&lt;div&gt;<span class="hljs-subst">$&#123;item&#125;</span>&lt;/div&gt;`</span>;<br>&#125;);<br><span class="hljs-title function_">messageBoxMutiple</span>(str, <span class="hljs-string">&quot;查看用户信息&quot;</span>, <span class="hljs-keyword">function</span> (<span class="hljs-params"></span>) &#123;&#125;);<br></code></pre></td></tr></table></figure>

<blockquote>
<p>第二个，在网上找到的，<a target="_blank" rel="noopener" href="https://blog.csdn.net/Dandrose/article/details/118969087">博客</a></p>
<p>这里仅作记录，请前往该<a target="_blank" rel="noopener" href="https://blog.csdn.net/Dandrose/article/details/118969087">博客</a>支持原创</p>
</blockquote>
<ol>
<li>创建组件Dialog.vue</li>
</ol>
<figure class="highlight plaintext"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br><span class="line">94</span><br><span class="line">95</span><br><span class="line">96</span><br><span class="line">97</span><br><span class="line">98</span><br><span class="line">99</span><br><span class="line">100</span><br><span class="line">101</span><br><span class="line">102</span><br><span class="line">103</span><br><span class="line">104</span><br><span class="line">105</span><br><span class="line">106</span><br><span class="line">107</span><br><span class="line">108</span><br><span class="line">109</span><br><span class="line">110</span><br><span class="line">111</span><br><span class="line">112</span><br><span class="line">113</span><br><span class="line">114</span><br><span class="line">115</span><br><span class="line">116</span><br><span class="line">117</span><br><span class="line">118</span><br><span class="line">119</span><br><span class="line">120</span><br><span class="line">121</span><br><span class="line">122</span><br><span class="line">123</span><br><span class="line">124</span><br><span class="line">125</span><br><span class="line">126</span><br><span class="line">127</span><br><span class="line">128</span><br><span class="line">129</span><br><span class="line">130</span><br><span class="line">131</span><br><span class="line">132</span><br><span class="line">133</span><br><span class="line">134</span><br><span class="line">135</span><br><span class="line">136</span><br><span class="line">137</span><br><span class="line">138</span><br><span class="line">139</span><br><span class="line">140</span><br><span class="line">141</span><br><span class="line">142</span><br><span class="line">143</span><br><span class="line">144</span><br><span class="line">145</span><br><span class="line">146</span><br><span class="line">147</span><br><span class="line">148</span><br><span class="line">149</span><br><span class="line">150</span><br><span class="line">151</span><br><span class="line">152</span><br><span class="line">153</span><br><span class="line">154</span><br><span class="line">155</span><br><span class="line">156</span><br><span class="line">157</span><br><span class="line">158</span><br><span class="line">159</span><br><span class="line">160</span><br><span class="line">161</span><br><span class="line">162</span><br><span class="line">163</span><br><span class="line">164</span><br><span class="line">165</span><br><span class="line">166</span><br><span class="line">167</span><br><span class="line">168</span><br><span class="line">169</span><br><span class="line">170</span><br><span class="line">171</span><br><span class="line">172</span><br><span class="line">173</span><br><span class="line">174</span><br><span class="line">175</span><br><span class="line">176</span><br><span class="line">177</span><br><span class="line">178</span><br><span class="line">179</span><br><span class="line">180</span><br><span class="line">181</span><br><span class="line">182</span><br><span class="line">183</span><br><span class="line">184</span><br><span class="line">185</span><br><span class="line">186</span><br><span class="line">187</span><br><span class="line">188</span><br><span class="line">189</span><br><span class="line">190</span><br><span class="line">191</span><br><span class="line">192</span><br><span class="line">193</span><br><span class="line">194</span><br><span class="line">195</span><br><span class="line">196</span><br><span class="line">197</span><br><span class="line">198</span><br><span class="line">199</span><br><span class="line">200</span><br><span class="line">201</span><br><span class="line">202</span><br><span class="line">203</span><br><span class="line">204</span><br><span class="line">205</span><br><span class="line">206</span><br><span class="line">207</span><br><span class="line">208</span><br><span class="line">209</span><br><span class="line">210</span><br><span class="line">211</span><br><span class="line">212</span><br><span class="line">213</span><br><span class="line">214</span><br><span class="line">215</span><br><span class="line">216</span><br><span class="line">217</span><br><span class="line">218</span><br><span class="line">219</span><br><span class="line">220</span><br><span class="line">221</span><br><span class="line">222</span><br><span class="line">223</span><br><span class="line">224</span><br><span class="line">225</span><br><span class="line">226</span><br><span class="line">227</span><br><span class="line">228</span><br><span class="line">229</span><br><span class="line">230</span><br><span class="line">231</span><br><span class="line">232</span><br><span class="line">233</span><br><span class="line">234</span><br><span class="line">235</span><br><span class="line">236</span><br><span class="line">237</span><br><span class="line">238</span><br><span class="line">239</span><br><span class="line">240</span><br><span class="line">241</span><br><span class="line">242</span><br><span class="line">243</span><br><span class="line">244</span><br><span class="line">245</span><br><span class="line">246</span><br><span class="line">247</span><br><span class="line">248</span><br><span class="line">249</span><br><span class="line">250</span><br><span class="line">251</span><br><span class="line">252</span><br><span class="line">253</span><br><span class="line">254</span><br><span class="line">255</span><br><span class="line">256</span><br><span class="line">257</span><br><span class="line">258</span><br><span class="line">259</span><br><span class="line">260</span><br><span class="line">261</span><br><span class="line">262</span><br><span class="line">263</span><br><span class="line">264</span><br><span class="line">265</span><br><span class="line">266</span><br><span class="line">267</span><br><span class="line">268</span><br><span class="line">269</span><br><span class="line">270</span><br><span class="line">271</span><br><span class="line">272</span><br><span class="line">273</span><br><span class="line">274</span><br><span class="line">275</span><br><span class="line">276</span><br><span class="line">277</span><br><span class="line">278</span><br><span class="line">279</span><br><span class="line">280</span><br><span class="line">281</span><br><span class="line">282</span><br><span class="line">283</span><br><span class="line">284</span><br><span class="line">285</span><br><span class="line">286</span><br><span class="line">287</span><br><span class="line">288</span><br><span class="line">289</span><br><span class="line">290</span><br><span class="line">291</span><br><span class="line">292</span><br><span class="line">293</span><br><span class="line">294</span><br><span class="line">295</span><br><span class="line">296</span><br><span class="line">297</span><br><span class="line">298</span><br><span class="line">299</span><br><span class="line">300</span><br><span class="line">301</span><br><span class="line">302</span><br></pre></td><td class="code"><pre><code class="hljs vue">&lt;template&gt;<br>  &lt;div class=&quot;m-dialog-mask&quot; @click.self=&quot;onBlur&quot;&gt;<br>    &lt;div :class=&quot;[&#x27;m-dialog&#x27;, center ? &#x27;relative-hv-center&#x27; : &#x27;top-center&#x27;]&quot; :style=&quot;`width: $&#123;dialogWidth&#125;; height: $&#123;dialogHeight&#125;;`&quot;&gt;<br>      &lt;div class=&quot;m-dialog-content&quot; :class=&quot;&#123;loading: loading&#125;&quot;&gt;<br>        &lt;div class=&quot;m-spin-dot&quot; v-show=&quot;loading&quot;&gt;<br>          &lt;span class=&quot;u-dot-item&quot;&gt;&lt;/span&gt;<br>          &lt;span class=&quot;u-dot-item&quot;&gt;&lt;/span&gt;<br>          &lt;span class=&quot;u-dot-item&quot;&gt;&lt;/span&gt;<br>          &lt;span class=&quot;u-dot-item&quot;&gt;&lt;/span&gt;<br>        &lt;/div&gt;<br>        &lt;svg @click=&quot;onFullScreen&quot; v-show=&quot;!fullScreen&amp;&amp;switchFullscreen&quot; class=&quot;u-screen&quot; viewBox=&quot;64 64 896 896&quot; data-icon=&quot;fullscreen&quot; aria-hidden=&quot;true&quot; focusable=&quot;false&quot;&gt;&lt;path d=&quot;M290 236.4l43.9-43.9a8.01 8.01 0 0 0-4.7-13.6L169 160c-5.1-.6-9.5 3.7-8.9 8.9L179 329.1c.8 6.6 8.9 9.4 13.6 4.7l43.7-43.7L370 423.7c3.1 3.1 8.2 3.1 11.3 0l42.4-42.3c3.1-3.1 3.1-8.2 0-11.3L290 236.4zm352.7 187.3c3.1 3.1 8.2 3.1 11.3 0l133.7-133.6 43.7 43.7a8.01 8.01 0 0 0 13.6-4.7L863.9 169c.6-5.1-3.7-9.5-8.9-8.9L694.8 179c-6.6.8-9.4 8.9-4.7 13.6l43.9 43.9L600.3 370a8.03 8.03 0 0 0 0 11.3l42.4 42.4zM845 694.9c-.8-6.6-8.9-9.4-13.6-4.7l-43.7 43.7L654 600.3a8.03 8.03 0 0 0-11.3 0l-42.4 42.3a8.03 8.03 0 0 0 0 11.3L734 787.6l-43.9 43.9a8.01 8.01 0 0 0 4.7 13.6L855 864c5.1.6 9.5-3.7 8.9-8.9L845 694.9zm-463.7-94.6a8.03 8.03 0 0 0-11.3 0L236.3 733.9l-43.7-43.7a8.01 8.01 0 0 0-13.6 4.7L160.1 855c-.6 5.1 3.7 9.5 8.9 8.9L329.2 845c6.6-.8 9.4-8.9 4.7-13.6L290 787.6 423.7 654c3.1-3.1 3.1-8.2 0-11.3l-42.4-42.4z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;<br>        &lt;svg @click=&quot;onFullScreen&quot; v-show=&quot;fullScreen&amp;&amp;switchFullscreen&quot; class=&quot;u-screen&quot; viewBox=&quot;64 64 896 896&quot; data-icon=&quot;fullscreen-exit&quot; aria-hidden=&quot;true&quot; focusable=&quot;false&quot;&gt;&lt;path d=&quot;M391 240.9c-.8-6.6-8.9-9.4-13.6-4.7l-43.7 43.7L200 146.3a8.03 8.03 0 0 0-11.3 0l-42.4 42.3a8.03 8.03 0 0 0 0 11.3L280 333.6l-43.9 43.9a8.01 8.01 0 0 0 4.7 13.6L401 410c5.1.6 9.5-3.7 8.9-8.9L391 240.9zm10.1 373.2L240.8 633c-6.6.8-9.4 8.9-4.7 13.6l43.9 43.9L146.3 824a8.03 8.03 0 0 0 0 11.3l42.4 42.3c3.1 3.1 8.2 3.1 11.3 0L333.7 744l43.7 43.7A8.01 8.01 0 0 0 391 783l18.9-160.1c.6-5.1-3.7-9.4-8.8-8.8zm221.8-204.2L783.2 391c6.6-.8 9.4-8.9 4.7-13.6L744 333.6 877.7 200c3.1-3.1 3.1-8.2 0-11.3l-42.4-42.3a8.03 8.03 0 0 0-11.3 0L690.3 279.9l-43.7-43.7a8.01 8.01 0 0 0-13.6 4.7L614.1 401c-.6 5.2 3.7 9.5 8.8 8.9zM744 690.4l43.9-43.9a8.01 8.01 0 0 0-4.7-13.6L623 614c-5.1-.6-9.5 3.7-8.9 8.9L633 783.1c.8 6.6 8.9 9.4 13.6 4.7l43.7-43.7L824 877.7c3.1 3.1 8.2 3.1 11.3 0l42.4-42.3c3.1-3.1 3.1-8.2 0-11.3L744 690.4z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;<br>        &lt;svg @click=&quot;onClose&quot; class=&quot;u-close&quot; viewBox=&quot;64 64 896 896&quot; data-icon=&quot;close&quot; aria-hidden=&quot;true&quot; focusable=&quot;false&quot;&gt;&lt;path d=&quot;M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 0 0 203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;<br>        &lt;div class=&quot;m-dialog-header&quot;&gt;<br>          &lt;slot name=&quot;title&quot;&gt;<br>            &lt;div class=&quot;u-head&quot;&gt;&#123;&#123; title &#125;&#125;&lt;/div&gt;<br>          &lt;/slot&gt;<br>        &lt;/div&gt;<br>        &lt;div class=&quot;m-dialog-body&quot; :style=&quot;`height: calc($&#123;dialogHeight&#125; - $&#123;footer ? &#x27;158px&#x27;:&#x27;103px&#x27;&#125;);`&quot;&gt;<br>          &lt;slot&gt;&#123;&#123; content &#125;&#125;&lt;/slot&gt;<br>        &lt;/div&gt;<br>        &lt;div class=&quot;m-dialog-footer&quot; v-show=&quot;footer&quot;&gt;<br>          &lt;button class=&quot;u-cancel&quot; @click=&quot;onCancel&quot;&gt;&#123;&#123; cancelText &#125;&#125;&lt;/button&gt;<br>          &lt;button class=&quot;u-confirm&quot; @click=&quot;onConfirm&quot;&gt;&#123;&#123; okText &#125;&#125;&lt;/button&gt;<br>        &lt;/div&gt;<br>      &lt;/div&gt;<br>    &lt;/div&gt;<br>  &lt;/div&gt;<br>&lt;/template&gt;<br>&lt;script&gt;<br>export default &#123;<br>  name: &#x27;Dialog&#x27;,<br>  props: &#123;<br>    title: &#123; // 标题 string | slot<br>      type: String,<br>      default: &#x27;提示&#x27;<br>    &#125;,<br>    content: &#123; // 内容 string | slot<br>      type: String,<br>      default: &#x27;&#x27;<br>    &#125;,<br>    width: &#123; // 宽度，默认640<br>      type: Number,<br>      default: 640<br>    &#125;,<br>    height: &#123; // 高度，默认480<br>      type: Number,<br>      default: 480<br>    &#125;,<br>    switchFullscreen: &#123; // 是否允许切换全屏（允许后右上角会出现一个按钮）<br>      type: Boolean,<br>      default: false<br>    &#125;,<br>    cancelText: &#123; // 取消按钮文字<br>      type: String,<br>      default: &#x27;取消&#x27;<br>    &#125;,<br>    okText: &#123; // 确认按钮文字<br>      type: String,<br>      default: &#x27;确定&#x27;<br>    &#125;,<br>    footer: &#123; // 是否显示底部按钮，默认显示<br>      type: Boolean,<br>      default: true<br>    &#125;,<br>    center: &#123; // 水平垂直居中：true  固定高度水平居中：false<br>      type: Boolean,<br>      default: true<br>    &#125;,<br>    loading: &#123; // 加载中<br>      type: Boolean,<br>      default: false<br>    &#125;<br>  &#125;,<br>  data () &#123;<br>    return &#123;<br>      fullScreen: false<br>    &#125;<br>  &#125;,<br>  computed: &#123;<br>    dialogWidth () &#123;<br>      if (this.fullScreen) &#123;<br>        return &#x27;100%&#x27;<br>      &#125; else &#123;<br>        return this.width + &#x27;px&#x27;<br>      &#125;<br>    &#125;,<br>    dialogHeight () &#123;<br>      if (this.fullScreen) &#123;<br>        return &#x27;100vh&#x27;<br>      &#125; else &#123;<br>        return this.height + &#x27;px&#x27;<br>      &#125;<br>    &#125;<br>  &#125;,<br>  methods: &#123;<br>    onBlur () &#123;<br>      if (this.loading) &#123;<br>        this.$emit(&#x27;close&#x27;)<br>      &#125;<br>    &#125;,<br>    onFullScreen () &#123;<br>      this.fullScreen = !this.fullScreen<br>    &#125;,<br>    onClose () &#123;<br>      this.$emit(&#x27;close&#x27;)<br>    &#125;,<br>    onCancel () &#123;<br>      this.$emit(&#x27;cancel&#x27;)<br>    &#125;,<br>    onConfirm () &#123;<br>      this.$emit(&#x27;ok&#x27;)<br>    &#125;<br>  &#125;<br>&#125;<br>&lt;/script&gt;<br>&lt;style lang=&quot;less&quot; scoped&gt;<br>.flex-hv-center &#123; // 水平垂直居中方法①：弹性布局，随内容增大高度，并自适应水平垂直居中<br>  display: flex;<br>  justify-content: center;<br>  align-items: center;<br>&#125;<br>.relative-hv-center &#123; // 水平垂直居中方法②：相对定位，随内容增大高度，并自适应水平垂直居中<br>  position: relative;<br>  top: 50%;<br>  transform: translateY(-50%);<br>  -ms-transform: translateY(-50%);; /* IE 9 */<br>  -webkit-transform: translateY(-50%); /* Safari and Chrome */<br>&#125;<br>.top-center &#123; // 相对定位，固定高度，始终距离视图顶端100px<br>  position: relative;<br>  top: 100px;<br>&#125;<br>.m-dialog-mask &#123;<br>  position: fixed;<br>  top: 0;<br>  right: 0;<br>  bottom: 0;<br>  left: 0;<br>  width: 100%;<br>  height: 100%;<br>  z-index: 10000;<br>  background: rgba(0,0,0,0.45);<br>  .m-dialog &#123;<br>    margin: 0 auto;<br>    transition: all .3s ease;<br>    .m-spin-dot &#123; // 绝对定位，并设置水平垂直居中<br>      position: absolute;<br>      display: inline-block;<br>      right: 0;<br>      left: 0;<br>      top: 0;<br>      bottom: 0;<br>      margin: auto;<br>      width: 24px;<br>      height: 24px;<br>      transform: rotate(45deg);<br>      -ms-transform: rotate(45deg); /* Internet Explorer */<br>      -moz-transform: rotate(45deg); /* Firefox */<br>      -webkit-transform: rotate(45deg); /* Safari 和 Chrome */<br>      -o-transform: rotate(45deg); /* Opera */<br>      animation: rotate 1.2s linear infinite;<br>      -webkit-animation: rotate 1.2s linear infinite;<br>      @keyframes rotate &#123;<br>        100% &#123;transform: rotate(405deg);&#125;<br>      &#125;<br>      .u-dot-item &#123; // 单个圆点样式<br>        position: absolute;<br>        width: 8px;<br>        height: 8px;<br>        background: #1890ff;<br>        border-radius: 50%;<br>        opacity: .3;<br>        animation: spinMove 1s linear infinite alternate;<br>        -webkit-animation: spinMove 1s linear infinite alternate;<br>        @keyframes spinMove &#123;<br>          100% &#123;opacity: 1;&#125;<br>        &#125;<br>      &#125;<br>      .u-dot-item:first-child &#123;<br>        top: 0;<br>        left: 0;<br>      &#125;<br>      .u-dot-item:nth-child(2) &#123;<br>        top: 0;<br>        right: 0;<br>        animation-delay: .4s;<br>        -webkit-animation-delay: .4s;<br>      &#125;<br>      .u-dot-item:nth-child(3) &#123;<br>        bottom: 0;<br>        right: 0;<br>        animation-delay: .8s;<br>        -webkit-animation-delay: .8s;<br>      &#125;<br>      .u-dot-item:last-child &#123;<br>        bottom: 0;<br>        left: 0;<br>        animation-delay: 1.2s;<br>        -webkit-animation-delay: 1.2s;<br>      &#125;<br>    &#125;<br>    .loading &#123; // 加载过程背景虚化<br>      background: rgb(248, 248, 248) !important;<br>      pointer-events: none; // 屏蔽鼠标事件<br>    &#125;<br>    .m-dialog-content &#123;<br>      position: relative;<br>      background: #fff;<br>      border-radius: 4px;<br>      box-shadow: 0 4px 12px rgba(0,0,0,.1);<br>      .u-screen &#123;<br>        .u-close();<br>        right: 64px;<br>      &#125;<br>      .u-close &#123;<br>        width: 16px;<br>        height: 16px;<br>        position: absolute;<br>        top: 19px;<br>        right: 24px;<br>        fill: rgba(0,0,0,.45);<br>        cursor: pointer;<br>        transition: fill .3s;<br>        &amp;:hover &#123;<br>          fill: rgba(0,0,0,.75);<br>        &#125;<br>      &#125;<br>      .m-dialog-header &#123;<br>        height: 22px;<br>        padding: 16px 24px;<br>        color: rgba(0,0,0,.65);<br>        border-radius: 4px 4px 0 0;<br>        border-bottom: 1px solid #e8e8e8;<br>        .u-head &#123;<br>          margin: 0;<br>          color: rgba(0,0,0,.85);<br>          font-weight: 500;<br>          font-size: 16px;<br>          line-height: 22px;<br>          word-wrap: break-word;<br>        &#125;<br>      &#125;<br>      .m-dialog-body &#123;<br>        padding: 24px;<br>        font-size: 16px;<br>        line-height: 1.5;<br>        word-wrap: break-word;<br>        overflow: auto;<br>        transition: all .3s;<br>      &#125;<br>      .m-dialog-footer &#123;<br>        padding: 10px 16px;<br>        text-align: right;<br>        border-top: 1px solid #e8e8e8;<br>        .u-cancel &#123;<br>          height: 32px;<br>          line-height: 32px;<br>          padding: 0 15px;<br>          font-size: 16px;<br>          border-radius: 4px;<br>          color: rgba(0,0,0,.65);<br>          background: #fff;<br>          border: 1px solid #d9d9d9;<br>          cursor: pointer;<br>          transition: all .3s cubic-bezier(.645,.045,.355,1);<br>          &amp;:hover &#123;<br>            color: #40a9ff;<br>            border-color: #40a9ff;<br>          &#125;<br>          &amp;:focus &#123;<br>            color: #096dd9;<br>            border-color: #096dd9;<br>          &#125;<br>        &#125;<br>        .u-confirm &#123;<br>          margin-left: 8px;<br>          height: 32px;<br>          line-height: 32px;<br>          padding: 0 15px;<br>          font-size: 16px;<br>          border-radius: 4px;<br>          background: #1890ff;<br>          border: 1px solid #1890ff;<br>          color: #fff;<br>          transition: all .3s cubic-bezier(.645,.045,.355,1);<br>          cursor: pointer;<br>          &amp;:hover &#123;<br>            color: #fff;<br>            background: #40a9ff;<br>            border-color: #40a9ff;<br>          &#125;<br>          &amp;:focus &#123;<br>            background: #096dd9;<br>            border-color: #096dd9;<br>          &#125;<br>        &#125;<br>      &#125;<br>    &#125;<br>  &#125;<br>&#125;<br>&lt;/style&gt;<br></code></pre></td></tr></table></figure>

<ol start="2">
<li>使用Dialog组件弹出对话框</li>
</ol>
<figure class="highlight js"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br></pre></td><td class="code"><pre><code class="hljs js">&lt;<span class="hljs-title class_">Dialog</span><br>  :title=<span class="hljs-string">&quot;title&quot;</span><br>  :width=<span class="hljs-string">&quot;720&quot;</span><br>  :height=<span class="hljs-string">&quot;480&quot;</span><br>  :content=<span class="hljs-string">&quot;content&quot;</span><br>  :footer=<span class="hljs-string">&quot;footer&quot;</span><br>  cancelText=<span class="hljs-string">&quot;取消&quot;</span><br>  okText=<span class="hljs-string">&quot;确认&quot;</span><br>  switchFullscreen<br>  @close=<span class="hljs-string">&quot;onClose&quot;</span><br>  @cancel=<span class="hljs-string">&quot;onCancel&quot;</span><br>  @ok=<span class="hljs-string">&quot;onConfirm&quot;</span><br>  :center=<span class="hljs-string">&quot;center&quot;</span><br>  :loading=<span class="hljs-string">&quot;loading&quot;</span><br>  v-show=<span class="hljs-string">&quot;visible&quot;</span>&gt;<br>  <span class="language-xml"><span class="hljs-tag">&lt;<span class="hljs-name">template</span> #<span class="hljs-attr">title</span>&gt;</span></span><br><span class="language-xml">    <span class="hljs-tag">&lt;<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">&quot;u-title&quot;</span>&gt;</span>Title<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span></span><br><span class="language-xml">  <span class="hljs-tag">&lt;/<span class="hljs-name">template</span>&gt;</span></span><br>  <span class="language-xml"><span class="hljs-tag">&lt;<span class="hljs-name">p</span>&gt;</span>Bla bla ...<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span></span><br>  <span class="language-xml"><span class="hljs-tag">&lt;<span class="hljs-name">p</span>&gt;</span>Bla bla ...<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span></span><br>  <span class="language-xml"><span class="hljs-tag">&lt;<span class="hljs-name">p</span>&gt;</span>Bla bla ...<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span></span><br>&lt;/<span class="hljs-title class_">Dialog</span>&gt;<br><span class="hljs-keyword">import</span> <span class="hljs-title class_">Dialog</span> <span class="hljs-keyword">from</span> <span class="hljs-string">&#x27;@/components/Dialog&#x27;</span><br><span class="hljs-attr">components</span>: &#123;<br>    <span class="hljs-title class_">Dialog</span><br>&#125;,<br>data () &#123;<br>    <span class="hljs-keyword">return</span> &#123;<br>        <span class="hljs-attr">visible</span>: <span class="hljs-literal">false</span>,<br>	    <span class="hljs-attr">content</span>: <span class="hljs-string">&#x27;&#x27;</span><br>    &#125;<br>&#125;,<br><span class="hljs-attr">methods</span>: &#123;<br>    onDialog (content) &#123; <span class="hljs-comment">// 调用Dialog弹出对话框</span><br>      <span class="hljs-variable language_">this</span>.<span class="hljs-property">content</span> = <span class="hljs-string">&#x27;Some descriptions ...&#x27;</span><br>      <span class="hljs-variable language_">this</span>.<span class="hljs-property">visible</span> = <span class="hljs-literal">true</span><br>    &#125;,<br>    onClose () &#123; <span class="hljs-comment">// 关闭dialog</span><br>      <span class="hljs-variable language_">this</span>.<span class="hljs-property">visible</span> = <span class="hljs-literal">false</span><br>    &#125;,<br>    onCancel () &#123; <span class="hljs-comment">// “取消”按钮回调</span><br>      <span class="hljs-variable language_">this</span>.<span class="hljs-property">visible</span> = <span class="hljs-literal">false</span><br>    &#125;,<br>    onConfirm () &#123; <span class="hljs-comment">// “确定”按钮回调</span><br>      <span class="hljs-variable language_">this</span>.<span class="hljs-property">visible</span> = <span class="hljs-literal">false</span><br>    &#125;<br>&#125;<br></code></pre></td></tr></table></figure>



<h2 id="更改每一行的数据"><a href="#更改每一行的数据" class="headerlink" title="更改每一行的数据"></a>更改每一行的数据</h2><blockquote>
<p>在表格内更改每一行的数据</p>
</blockquote>
<figure class="highlight plaintext"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br></pre></td><td class="code"><pre><code class="hljs vue">&lt;el-table-column<br>    prop=&quot;phone&quot;<br>    header-align=&quot;center&quot;<br>    align=&quot;center&quot;<br>    label=&quot;手机号&quot;&gt;<br>    &lt;template slot-scope=&quot;scope&quot;&gt;<br>        &lt;el-tag type=&quot;info&quot;&gt;&#123;&#123;scope.row.phone&#125;&#125;&lt;/el-tag&gt;<br>        &lt;el-button type=&quot;text&quot; size=&quot;small&quot; @click=&quot;seeDialog(scope.row.phone)&quot;&gt;手机号&lt;/el-button&gt;<br>    &lt;/template&gt;<br>&lt;/el-table-column&gt;<br></code></pre></td></tr></table></figure>



<h2 id="选择器"><a href="#选择器" class="headerlink" title="选择器"></a>选择器</h2><figure class="highlight plaintext"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br></pre></td><td class="code"><pre><code class="hljs vue">&lt;el-form-item label=&quot;用户类型&quot; prop=&quot;gender&quot;&gt;<br>    &lt;el-select v-model=&quot;dataForm.gender&quot; placeholder=&quot;请选择接种人性别&quot;&gt;<br>        &lt;el-option v-for=&quot;item in options&quot; :key=&quot;item.value&quot; :label=&quot;item.label&quot; :value=&quot;item.value&quot;&gt;<br>        &lt;/el-option&gt;<br>    &lt;/el-select&gt;<br>&lt;/el-form-item&gt;<br><br>&lt;!-- data --&gt;<br>options:[&#123;<br>    value:&quot;1&quot;,<br>    label:&quot;男&quot;<br>&#125;,<br>&#123;<br>    value:&quot;0&quot;,<br>    label:&quot;女&quot;<br>&#125;],<br></code></pre></td></tr></table></figure>



<h2 id="Can’t-resolve-‘less-loader’"><a href="#Can’t-resolve-‘less-loader’" class="headerlink" title="Can’t resolve ‘less-loader’"></a>Can’t resolve ‘less-loader’</h2><figure class="highlight awk"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><code class="hljs awk"><span class="hljs-regexp">//</span> 安装<br>npm install --save-dev less-loader less<br><span class="hljs-regexp">//</span> 若继续报错<br><span class="hljs-regexp">//</span> UnhandledPromiseRejectionWarning: TypeError: loaderContext.getResolve is not …<br><span class="hljs-regexp">//</span> 执行以下命令，在版本位置处选择合适的版本<br>npm install less-loader@<span class="hljs-number">5.0</span>.<span class="hljs-number">0</span> -D<br></code></pre></td></tr></table></figure>

<h2 id="修改store内的数据"><a href="#修改store内的数据" class="headerlink" title="修改store内的数据"></a>修改store内的数据</h2><figure class="highlight js"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><code class="hljs js"><span class="hljs-variable language_">this</span>.<span class="hljs-property">$store</span>.<span class="hljs-title function_">dispatch</span>(<span class="hljs-string">&#x27;asyncUpdateUser&#x27;</span>,&#123;<br>  <span class="hljs-attr">email</span>:<span class="hljs-variable language_">this</span>.<span class="hljs-property">email</span><br>&#125;)<br></code></pre></td></tr></table></figure>

                
              </div>
            
            <hr/>
            <div>
              <div class="post-metas my-3">
  
    <div class="post-meta mr-3 d-flex align-items-center">
      <i class="iconfont icon-category"></i>
      

<span class="category-chains">
  
  
    
      <span class="category-chain">
        
  <a href="/categories/vue%E9%9C%80%E6%B1%82/" class="category-chain-item">vue需求</a>
  
  

      </span>
    
  
</span>

    </div>
  
  
    <div class="post-meta">
      <i class="iconfont icon-tags"></i>
      
        <a href="/tags/vue%E9%9C%80%E6%B1%82/">#vue需求</a>
      
    </div>
  
</div>


              
  

  <div class="license-box my-3">
    <div class="license-title">
      <div>vue需求</div>
      <div>http://example.com/2023/03/26/编程语言/Vue/Vue2/项目中遇到的问题/</div>
    </div>
    <div class="license-meta">
      
        <div class="license-meta-item">
          <div>作者</div>
          <div>深海火锅店</div>
        </div>
      
      
        <div class="license-meta-item license-meta-date">
          <div>发布于</div>
          <div>2023年3月26日</div>
        </div>
      
      
      
        <div class="license-meta-item">
          <div>许可协议</div>
          <div>
            
              
              
                <a target="_blank" href="https://creativecommons.org/licenses/by/4.0/">
                  <span class="hint--top hint--rounded" aria-label="BY - 署名">
                    <i class="iconfont icon-by"></i>
                  </span>
                </a>
              
            
          </div>
        </div>
      
    </div>
    <div class="license-icon iconfont"></div>
  </div>



              
                <div class="post-prevnext my-3">
                  <article class="post-prev col-6">
                    
                    
                      <a href="/2023/03/26/%E7%BC%96%E7%A8%8B%E8%AF%AD%E8%A8%80/Java/%E5%AD%A6%E4%B9%A0/%E6%A1%86%E6%9E%B6/SpringSecurity/SpringSecurity%E5%AF%86%E7%A0%81%E5%8A%A0%E5%AF%86%E5%AD%98%E5%82%A8/" title="SpringSecurity密码加密存储">
                        <i class="iconfont icon-arrowleft"></i>
                        <span class="hidden-mobile">SpringSecurity密码加密存储</span>
                        <span class="visible-mobile">上一篇</span>
                      </a>
                    
                  </article>
                  <article class="post-next col-6">
                    
                    
                      <a href="/2023/03/25/%E7%B3%BB%E7%BB%9F%E9%85%8D%E7%BD%AE/%E7%BC%96%E7%A8%8B%E9%85%8D%E7%BD%AE/%E7%8E%AF%E5%A2%83%E9%85%8D%E7%BD%AE/Hbuilder/hbuilder%E9%85%8D%E7%BD%AE/" title="hbuilder配置">
                        <span class="hidden-mobile">hbuilder配置</span>
                        <span class="visible-mobile">下一篇</span>
                        <i class="iconfont icon-arrowright"></i>
                      </a>
                    
                  </article>
                </div>
              
            </div>

            
          </article>
        </div>
      </div>
    </div>

    <div class="side-col d-none d-lg-block col-lg-2">
      
  <aside class="sidebar" style="margin-left: -1rem">
    <div id="toc">
  <p class="toc-header"><i class="iconfont icon-list"></i>&nbsp;目录</p>
  <div class="toc-body" id="toc-body"></div>
</div>



  </aside>


    </div>
  </div>
</div>





  



  



  



  



  







    

    
      <a id="scroll-top-button" aria-label="TOP" href="#" role="button">
        <i class="iconfont icon-arrowup" aria-hidden="true"></i>
      </a>
    

    
      <div class="modal fade" id="modalSearch" tabindex="-1" role="dialog" aria-labelledby="ModalLabel"
     aria-hidden="true">
  <div class="modal-dialog modal-dialog-scrollable modal-lg" role="document">
    <div class="modal-content">
      <div class="modal-header text-center">
        <h4 class="modal-title w-100 font-weight-bold">搜索</h4>
        <button type="button" id="local-search-close" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">&times;</span>
        </button>
      </div>
      <div class="modal-body mx-3">
        <div class="md-form mb-5">
          <input type="text" id="local-search-input" class="form-control validate">
          <label data-error="x" data-success="v" for="local-search-input">关键词</label>
        </div>
        <div class="list-group" id="local-search-result"></div>
      </div>
    </div>
  </div>
</div>

    

    
  </main>

  <footer>
    <div class="footer-inner">
  
    <div class="footer-content">
       <a href="https://hexo.io" target="_blank" rel="nofollow noopener"><span>Hexo</span></a> <i class="iconfont icon-love"></i> <a href="https://github.com/fluid-dev/hexo-theme-fluid" target="_blank" rel="nofollow noopener"><span>Fluid</span></a> 
    </div>
  
  
    <div class="statistics">
  
  

  
    
      <span id="busuanzi_container_site_pv" style="display: none">
        总访问量 
        <span id="busuanzi_value_site_pv"></span>
         次
      </span>
    
    
      <span id="busuanzi_container_site_uv" style="display: none">
        总访客数 
        <span id="busuanzi_value_site_uv"></span>
         人
      </span>
    
    
  
</div>

  
  
  
</div>

  </footer>

  <!-- Scripts -->
  
  <script  src="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.js" ></script>
  <link  rel="stylesheet" href="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.css" />

  <script>
    NProgress.configure({"showSpinner":false,"trickleSpeed":100})
    NProgress.start()
    window.addEventListener('load', function() {
      NProgress.done();
    })
  </script>


<script  src="https://lib.baomitu.com/jquery/3.6.0/jquery.min.js" ></script>
<script  src="https://lib.baomitu.com/twitter-bootstrap/4.6.1/js/bootstrap.min.js" ></script>
<script  src="/js/events.js" ></script>
<script  src="/js/plugins.js" ></script>


  <script  src="https://lib.baomitu.com/typed.js/2.0.12/typed.min.js" ></script>
  <script>
    (function (window, document) {
      var typing = Fluid.plugins.typing;
      var subtitle = document.getElementById('subtitle');
      if (!subtitle || !typing) {
        return;
      }
      var text = subtitle.getAttribute('data-typed-text');
      
        typing(text);
      
    })(window, document);
  </script>




  
    <script  src="/js/img-lazyload.js" ></script>
  




  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/tocbot/4.18.2/tocbot.min.js', function() {
    var toc = jQuery('#toc');
    if (toc.length === 0 || !window.tocbot) { return; }
    var boardCtn = jQuery('#board-ctn');
    var boardTop = boardCtn.offset().top;

    window.tocbot.init(Object.assign({
      tocSelector     : '#toc-body',
      contentSelector : '.markdown-body',
      linkClass       : 'tocbot-link',
      activeLinkClass : 'tocbot-active-link',
      listClass       : 'tocbot-list',
      isCollapsedClass: 'tocbot-is-collapsed',
      collapsibleClass: 'tocbot-is-collapsible',
      scrollSmooth    : true,
      includeTitleTags: true,
      headingsOffset  : -boardTop,
    }, CONFIG.toc));
    if (toc.find('.toc-list-item').length > 0) {
      toc.css('visibility', 'visible');
    }

    Fluid.events.registerRefreshCallback(function() {
      if ('tocbot' in window) {
        tocbot.refresh();
        var toc = jQuery('#toc');
        if (toc.length === 0 || !tocbot) {
          return;
        }
        if (toc.find('.toc-list-item').length > 0) {
          toc.css('visibility', 'visible');
        }
      }
    });
  });
</script>


  <script src=https://lib.baomitu.com/clipboard.js/2.0.11/clipboard.min.js></script>

  <script>Fluid.plugins.codeWidget();</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/anchor-js/4.3.1/anchor.min.js', function() {
    window.anchors.options = {
      placement: CONFIG.anchorjs.placement,
      visible  : CONFIG.anchorjs.visible
    };
    if (CONFIG.anchorjs.icon) {
      window.anchors.options.icon = CONFIG.anchorjs.icon;
    }
    var el = (CONFIG.anchorjs.element || 'h1,h2,h3,h4,h5,h6').split(',');
    var res = [];
    for (var item of el) {
      res.push('.markdown-body > ' + item.trim());
    }
    if (CONFIG.anchorjs.placement === 'left') {
      window.anchors.options.class = 'anchorjs-link-left';
    }
    window.anchors.add(res.join(', '));

    Fluid.events.registerRefreshCallback(function() {
      if ('anchors' in window) {
        anchors.removeAll();
        var el = (CONFIG.anchorjs.element || 'h1,h2,h3,h4,h5,h6').split(',');
        var res = [];
        for (var item of el) {
          res.push('.markdown-body > ' + item.trim());
        }
        if (CONFIG.anchorjs.placement === 'left') {
          anchors.options.class = 'anchorjs-link-left';
        }
        anchors.add(res.join(', '));
      }
    });
  });
</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.js', function() {
    Fluid.plugins.fancyBox();
  });
</script>


  <script>Fluid.plugins.imageCaption();</script>

  <script  src="/js/local-search.js" ></script>

  <script defer src="https://busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js" ></script>




  
<script src="//cdn.jsdelivr.net/gh/EmoryHuang/BlogBeautify@1.1/DynamicRibbon.min.js"></script>



<!-- 主题的启动项，将它保持在最底部 -->
<!-- the boot of the theme, keep it at the bottom -->
<script  src="/js/boot.js" ></script>


  

  <noscript>
    <div class="noscript-warning">博客在允许 JavaScript 运行的环境下浏览效果更佳</div>
  </noscript>
</body>
</html>
